//
//  NSMutableArray+array.m
//  WTMSeller
//
//  Created by lxj on 2018/2/2.
//  Copyright © 2018年 LQ. All rights reserved.
//

#import "NSMutableArray+array.h"

@implementation NSMutableArray (array)

///把数组里的image 换成 地址
+ (NSMutableArray *)changeArray:(NSMutableArray *)array imageArr:(NSArray *)imageArr{
    NSMutableArray *newArr =  [NSMutableArray arrayWithArray:array];
    int n = 0;
    for (int i = 0 ; i < array.count; i++) {
        id image = array[i];
        if ([image isKindOfClass:[UIImage class]]) {
            //先移除index 在加入
            [newArr removeObjectAtIndex:i];
            [newArr insertObject:imageArr[n] atIndex:i];
            n++;
        };
    }
    return newArr;
}

@end
